<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
import('ViewModel');
class PostsViewModel extends ViewModel{
   public $viewFields=array(
        'posts'=>array('id'=>'p_id','theme','content','dateline','author_id','forum_id','mood','is_good','_as'=>'p','_type'=>'left'),
        'user'=>array('id','username','name','email','gender','birth_day','phone','register_time','credits','login_time','is_online','head_img','role','_as'=>'u','_on'=>'u.id=p.author_id','_type'=>'left'),
        'forum'=>array('id','forum_name','parent_forum_id','parent_forum_name','_as'=>'f','_on'=>'f.id=p.forum_id','_type'=>'left')
    );
}
?>
